package com.taxi.driver.data.entity;

import com.taxi.driver.config.OrderStatus;

import java.util.List;

/**
 * 功能描述：订单信息
 */
public class OrderEntity {

    public String uuid;
    public Integer subStatus;
    public String passengerCom;
    public String driverCom;
    public String originDetailAddress;
    public String originAddress;
    public Double originLng;
    public Double originLat;
    public String destDetailAddress;
    public String destAddress;
    public Double destLng;
    public Double destLat;
    public Integer typeTime;
    public Integer typeTrip;
    public Double totalFare;
    public Long deparTime;
    public String actualPasNum;
    public String actualPasMob;
    public PassengerEntity passenger;
    public DriverEntity driver;
    public String comment;
    public Double tip;
    public String remark;
    public String cancelReason;
    public String actualFare;
    public String couponFare;
    public String payType;
    public String countdown;
    public String overTime;
    public String report;
    public String carModelsLevelUuid;
    public String waitDuration;
    public String income;
    public String orderCount;
    public List<OrderCostItemEntity> orderCostItemBean;

    public Integer mainStatus;
    public Integer canPickUp;
    public Integer canHurryPay;
    public String title;
    public String orderNo;
    public String planTrip;

    public Integer typeModule; //订单模块类型（1：出租车，2：专车，3：拼车，4：快车，5：货的，6：骑手，7：搬家）
    public Integer typeTripNew; //订单行程类型（1：用车，2：日租，3：半日租，4：送机，5：接机）
    public Integer typeTimeNew; //订单时效类型（1：实时，2：预约）
    public Integer typeInteractive; //订单交互类型（1：推单，2：抢单）

    public boolean isOrderOngoing() {
        return subStatus != null && (subStatus == OrderStatus.WAIT_ARRIVE_ORIGIN //去接乘客
                || subStatus == OrderStatus.WAIT_PASSENGER_GET_ON //到达目的地，等待乘客上车
                || subStatus == OrderStatus.DEPART);
    }
}
